<template>
  <div>
    <div class="wframe">
      <div class="mcontent">
        <div class="top clearfix">
          <div class="top_logo fl">
            <img src="./../../assets/img/logo.png" alt="">
          </div>
          <ul class="top_home fr">
            <li class="fl">
              <router-link to="/login">登录</router-link>
            </li>
            <li class="fl">
              <router-link to="/register">注册</router-link>
            </li>
          </ul>
        </div>
        <p class="mcontent_title">首页>{{contentTypeName}}</p>
        <div class="mcontent_main">
            <h1 class="mcontent_main_h1">{{noticeTitle}}</h1>
            <p class="mcontent_main_p">{{createTime}}</p>
            <div v-html="content">{{content}}</div>
        </div>
      </div>
    </div>
  </div>
</template>
<script>
  export default {
    data() {
      return {
        content:'',
        createTime:'',
        noticeTitle:'',
        contentTypeName:''
      }
    },
    mounted() {
      this.newp();
    },
    methods: {
      newp() {
        this.axios.get(this.lib.config.host.system + '/portal/findById/'+this.$route.query.id)
          .then((response) => {
              console.log(response)
            this.content=response.data.content;
            this.createTime=response.data.createTime;
            this.noticeTitle=response.data.noticeTitle;
            this.contentTypeName=response.data.contentTypeName ; 
          })
          .catch((error) => {
            console.log(error);
          });
      }

    }
  }

</script>
